// Bachelor of Software Engineering 
// Media Design School 
// Auckland
// New Zealand
// 
// (c) 2005 - 2014 Media Design School 
// 
// File Name : BackBuffer.h
// Description : BackBuffer header
// Author : Serge Radinovich
// Mail : srad015@hotmail.com


#pragma once

#include <Windows.h>

class BackBuffer
{
public:
	BackBuffer(HWND _hWnd, float _iWidth, float _iWHeight);
	~BackBuffer();

	HDC getDC();
	HBITMAP getOldObject();
	int Width();
	int Height();

	void Present();
	void Clear();
	void SetBackgroundDC(HDC _hDC);
private:
	//Disallow copying
	BackBuffer(const BackBuffer& b);
	BackBuffer& operator=(const BackBuffer& b);

	HWND m_hWnd;
	HDC m_hDC;
	HDC m_hBackgroundDC;
	HBITMAP m_hSurface;
	HBITMAP m_hOldObject;
	int m_iWidth;
	int m_iHeight;
};

